import sqlite3


# bg_id,name,introduction,geekRating,avgRating,numVoters
def init():
    con = sqlite3.connect('data.db')
    cur = con.cursor()
    cur.execute('''create table if not exists data(
        bg_id INTEGER primary key,
        name text,
        introductive text,
        geekRating text,
        avgRating text,
        numVoters text);''')    
    return con


def insert(tuple,con):
    cur = con.cursor()
    cur.execute("insert into data values (?,?,?,?,?,?)" , tuple)
    cur.execute("select * from data")

def dispose(con):
    con.close()




